/**
 * Created with IntelliJ IDEA.
 * User: Chris
 * Date: 10/15/13
 * Time: 5:50 PM
 * To change this template use File | Settings | File Templates.
 */
public class Brandonacci
{
    //FINAL TEST OF ERRYTIHNG FOREVER
    public static int brandonacci(int n)
    {
        if(n<=-15)
        {
            return ((-n)/3) +21;
        }
        else
        {
            int c1 = Brandonacci.brandonacci(n - 1);
            int c2 = Brandonacci.brandonacci(n - 5);
            return (c1/2)-(2*c2) - 12;
        }
    }

    public static void main (String[] args)
    {
        System.out.println(Brandonacci.brandonacci(0));
    }

}
